package com.gzbd.login.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.List;

/**
 *
 */
@Component
@ConfigurationProperties(prefix = "auth")
public class AuthConfig {

    private String tokenHead = "Bearer ";//默认值Bearer

    private String secret = "zc123456";

    private Long expiration = 604800L;

    private List<String> tokenExclusionUrl = new ArrayList<>();

    private List<String> authExclusionUrl = new ArrayList<>();

    private List<String> userTokenUrl = new ArrayList<>();

    private List<String> adminTokenUrl = new ArrayList<>();


    public String getTokenHead() {
        return tokenHead;
    }

    public void setTokenHead(String tokenHead) {
        this.tokenHead = tokenHead;
    }

    public String getSecret() {
        return secret;
    }

    public void setSecret(String secret) {
        this.secret = secret;
    }

    public Long getExpiration() {
        return expiration;
    }

    public void setExpiration(Long expiration) {
        this.expiration = expiration;
    }

    public List<String> getTokenExclusionUrl() {
        return tokenExclusionUrl;
    }

    public void setTokenExclusionUrl(List<String> tokenExclusionUrl) {
        this.tokenExclusionUrl = tokenExclusionUrl;
    }

    public List<String> getAuthExclusionUrl() {
        return authExclusionUrl;
    }

    public void setAuthExclusionUrl(List<String> authExclusionUrl) {
        this.authExclusionUrl = authExclusionUrl;
    }

    public List<String> getUserTokenUrl() {
        return userTokenUrl;
    }

    public void setUserTokenUrl(List<String> userTokenUrl) {
        this.userTokenUrl = userTokenUrl;
    }

    public List<String> getAdminTokenUrl() {
        return adminTokenUrl;
    }

    public void setAdminTokenUrl(List<String> adminTokenUrl) {
        this.adminTokenUrl = adminTokenUrl;
    }
}
